<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>jQuery带进度条全屏图片轮播代码 - 16素材网</title>

<link rel="stylesheet" type="text/css" href="css/style.css">

</head>
<body>

<div class="pic">
	<ul>
		<li style="background:url(images/bg1.jpg) center;">
			<img src="images/con1.png">
			<div class="nav"></div>
			<div class="bar"><p></p></div>
		</li>
		<li style="background:url(images/bg2.jpg) center;">
			<img src="images/con2.png">
			<div class="nav"></div>
			<div class="bar"><p></p></div>
		</li>
		<li style="background:url(images/bg3.jpg) center;">
			<img src="images/con3.png">
			<div class="nav"></div>
			<div class="bar"><p></p></div>
		</li>
	</ul>
</div>

<script type="text/javascript" src="js/jquery.js"></script>
<script type="text/javascript">
var i=0;
jummper();
function jummper(){
   $(".pic ul li").eq(i).find("img").css("left","-1180px");
   $(".pic ul li").eq(i).find("p").css("width","0px");
   $(".pic ul li").eq(i).find("img").animate({left:"0px"},500,function(){
	   //当图片移动完成后再加载进度条
	   //alert("当图片移动完成后再做操作");
		$(".pic ul li").eq(i).find("p").animate({width:"1174px"},8000,function(){
			$(".pic ul li").eq(i).find("img").animate({left:"1180px"},500,function(){
				i++;
				if(i>2)
				i=0;
				$(".pic ul li").eq(i).fadeIn(100).siblings().fadeOut(100);
			});
		});
   });
}
setInterval("jummper()",9100);
</script>

<div style="text-align:center;margin:50px 0; font:normal 14px/24px 'MicroSoft YaHei';">
<p>适用浏览器：IE8、360、FireFox、Chrome、Safari、Opera、傲游、搜狗、世界之窗.</p>
<p>来源：<a href="http://www.16sucai.com/" target="_blank">16素材网</a></p>
</div>
</body>
</html>
